<div class="container-fluid form-horizontal">

	<div class="col-xs-12 col-md-12 mt10">

		<div class="form-group">
			<label class="col-sm-2 col-xs-12 control-label checkbox">
				<input type="checkbox" name="template.name_flag" ng-model="template.name_flag" >
				产品名称
			</label>
			<div class="col-sm-4 col-xs-12">
				<input type="text" class="form-control" placeholder="产品名称" ng-model="saleobj.name" disabled>
			</div>
			<div class="col-sm-6 mt10">
				<font face="Courier" class="text-danger">此名称用于产品列表及订单名称</font>
			</div>
		</div>

		<div class="form-group">
			<label class="col-sm-2 col-xs-12 control-label checkbox">
				<input type="checkbox" name="template.name_inside_flag" ng-model="template.name_inside_flag" >
				产品名称
			</label>
			<div class="col-sm-4 col-xs-12">
				<input type="text" class="form-control" ng-model="saleobj.name_inside" placeholder="产品名称" disabled>
			</div>
			<div class="col-sm-6 mt10">
				<font face="Courier" class="text-danger">此名称用于内部使用</font>
			</div>
		</div>

		<div class="form-group">
			<label class="col-sm-2 col-xs-12 control-label checkbox">
				<input type="checkbox" name="template.asort_flag" ng-model="template.asort_flag" >
				产品排序
			</label>
			<div class="col-sm-4 col-xs-12">
				<input type="text" class="form-control" ng-model="saleobj.asort" placeholder="产品排序" disabled>
			</div>
			<div class="col-sm-6 mt10">
				<font face="Courier" class="text-danger">在产品列表中显示顺序</font>
			</div>
		</div>

		<div class="form-group">
			<label class="col-sm-2 col-xs-12 control-label checkbox">
				<input type="checkbox" name="template.price_type_flag" ng-value="true" ng-model="template.price_type_flag" >
				价格类型
			</label>
			<div class="col-sm-4 col-xs-12">
				<label class="radio-inline">
					<input type="radio" name="price_type" ng-value="'0'" ng-model="saleobj.price_type" disabled> 有效期模式
				</label>
				<label class="radio-inline">
					<input type="radio" name="price_type" ng-value="'1'" ng-model="saleobj.price_type" disabled> 价格日历模式
				</label>
			</div>
			<div class="col-sm-6 col-xs-12">
				<p class="form-control-static text-danger">
				</p>
			</div>
		</div>

		<div class="form-group">
			<label class="col-sm-2 col-xs-12 control-label checkbox">
				<input type="checkbox" name="template.sale_category_flag" ng-value="true" ng-model="template.sale_category_flag" >
				产品分类
			</label>
			<div class="col-sm-4  col-xs-12">
				<ui-select ng-model="saleobj.sale_category" theme="bootstrap" >
					<ui-select-match placeholder="请选择一个销售品分类">{{$select.selected.label}}</ui-select-match>
					<ui-select-choices repeat="item.value as item in page.categorylist | filter: $select.search">
						<span ng-bind-html="item.label | highlight: $select.search"></span>
						<span ng-bind-html="item.value | highlight: $select.search"></span>
					</ui-select-choices>
				</ui-select>
			</div>
			<div class="col-sm-6 mt10">
				<font face="Courier" class="text-danger">产品类别</font>
			</div>
		</div>

		<div class="form-group message">
			<label class="col-sm-2 col-xs-12 control-label">短信配置</label>
			<div class="col-sm-4 col-xs-12">
			</div>
			<div class="col-sm-6 mt10">
			</div>
		</div>

		<div class="panel panel-default message">
			<div class="form-group">
				<label class="col-sm-2 col-xs-12 control-label checkbox">
					<input type="checkbox" name="template.sms_type_flag" ng-value="true" ng-model="template.sms_type_flag" >
					发送类型
				</label>
				<div class="col-sm-4 col-xs-12">
					<label class="radio-inline">
						<input type="radio" name="sms_type" value="1" ng-model="saleobj.sms_type" disabled> 发送短信
					</label>
					<label class="radio-inline">
						<input type="radio" name="sms_type" value="0" ng-model="saleobj.sms_type" disabled> 不发短信
					</label>
				</div>
				<div class="col-sm-6 mt10">
					<font face="Courier" class="text-danger">下单出票之后是否发送短信</font>
				</div>
			</div>

			<div class="form-group">
				<label class="col-sm-2 col-xs-12 control-label checkbox">
					<input type="checkbox" name="template.sms_template_id_flag" ng-value="true" ng-model="template.sms_template_id_flag" >
					模板编号
				</label>
				<div class="col-sm-4 col-xs-12">
					<select class="form-control" ng-model="saleobj.sms_template_id" ng-change="changeSms(saleobj)"  disabled
						ng-options="sms.sms_template_id as sms.sms_template_id for sms in page.smslist">
						<option value="">  -- 空 --  </option>
					</select>
				</div>
				<div class="col-sm-6 mt10">
					<font face="Courier" class="text-danger">发送短信内容模板</font>
				</div>
			</div>

			<div class="form-group">
				<label class="col-sm-2 col-xs-12 control-label checkbox">
					<input type="checkbox" name="template.sms_diy_flag" ng-value="true" ng-model="template.sms_diy_flag" >
					补充内容
				</label>
				<div class="col-sm-4 col-xs-12">
					<textarea class="form-control" rows="3" ng-model="saleobj.sms_diy" disabled></textarea>
				</div>
				<div class="col-sm-6 mt10">
					<font face="Courier" class="text-danger">短信补充自定义内容</font>
				</div>
			</div>

		</div>

		<div class="form-group mt10">
			<label class="col-sm-2 col-xs-12 control-label checkbox">
				<input type="checkbox" name="template.sale_belong_flag" ng-value="true" ng-model="template.sale_belong_flag" >
				产品所属
			</label>
			<div class="col-sm-4 col-xs-12">
				<ui-select ng-model="saleobj.sale_belong" theme="bootstrap" disabled>
					<ui-select-match placeholder="请选择一个产品所属">{{$select.selected.label}}</ui-select-match>
					<ui-select-choices repeat="item.value as item in page.salebelonglist | filter: $select.search">
						<span ng-bind-html="item.label | highlight: $select.search"></span>
					</ui-select-choices>
				</ui-select>
			</div>
			<div class="col-sm-6 mt10">
				<font face="Courier" class="text-danger">非自营为接口对接产品</font>
			</div>
		</div>

		<div class="form-group mt10">
			<label class="col-sm-2 col-xs-12 control-label checkbox">
				<input type="checkbox" name="template.nopay_cancel_minute_flag" ng-value="true" ng-model="template.nopay_cancel_minute_flag" >
				过期时间
			</label>
			<div class="col-sm-4 col-xs-12">
				<select name="saleobj.nopay_cancel_minute" class="form-control" ng-model="saleobj.nopay_cancel_minute" disabled>
					<option value="10">10分钟</option>
					<option value="15">15分钟</option>
					<option value="30">30分钟</option>
					<option value="60">一小时</option>
					<option value="120">两小时</option>
				</select>
			</div>
			<div class="col-sm-6 mt10">
				<font face="Courier" class="text-danger">未支付订单超时时间</font>
			</div>
		</div>

		<div class="form-group">
			<form class="">
				<label class="col-sm-2 col-xs-12 control-label checkbox">
					<input type="checkbox" name="template.periodstart_flag" ng-value="true" ng-model="template.periodstart_flag" >
					有效期始
				</label>
				<div class="col-sm-4 form-inline">
					<div class="input-group">
						<input type="text" class="form-control" datepicker-popup="yyyy-MM-dd" ng-model="baseinfo.dateshow.periodstart.date.label"
						 is-open="baseinfo.dateshow.periodstart.date.opened" readonly close-text="关闭" current-text="今天" clear-text="清除" />
						<span class="input-group-btn">
							<button type="button" class="btn btn-default" 
									ng-click="baseinfo.dateshow.open($event, baseinfo.dateshow.periodstart.date)">
								<i class="glyphicon glyphicon-calendar"></i>
							</button>
						</span>
					</div>
				</div>
			</form>
			<div class="col-sm-6">
				<p class="form-control-static text-danger">产品可用时间开始时间</p>
			</div>
		</div>

		<div class="form-group">
			<form class="">
				<label class="col-sm-2 col-xs-12 control-label checkbox">
					<input type="checkbox" name="template.periodend_flag" ng-value="true" ng-model="template.periodend_flag" >
					有效期止
				</label>
				<div class="col-sm-4 form-inline">
					<div class="input-group">
						<input type="text" class="form-control" datepicker-popup="yyyy-MM-dd" ng-model="baseinfo.dateshow.periodend.date.label" is-open="baseinfo.dateshow.periodend.date.opened"
						 readonly close-text="关闭" current-text="今天" clear-text="清除" />
						<span class="input-group-btn">
							<button type="button" class="btn btn-default"  
									ng-click="baseinfo.dateshow.open($event, baseinfo.dateshow.periodend.date)">
								<i class="glyphicon glyphicon-calendar"></i>
							</button>
						</span>
					</div>
				</div>
			</form>
			<div class="col-sm-6">
				<p class="form-control-static text-danger">产品可用时间结束时间</p>
			</div>
		</div>

		<div class="form-group">
			<label class="col-sm-2 col-xs-12 control-label checkbox">
				<input type="checkbox" name="template.address_flag" ng-value="true" ng-model="template.address_flag" >
				地址信息
			</label>
			<div class="col-sm-4 col-xs-12">
				<label class="radio-inline">
					<input type="radio" name="address" value="0" ng-model="saleobj.address" disabled> 
					票种信息
				</label>
				<label class="radio-inline">
					<input type="radio" name="address" value="1" ng-model="saleobj.address" disabled >
					门店信息
				</label>
				<label class="radio-inline">
					<input type="radio" name="address" value="2" ng-model="saleobj.address" disabled >
					酒店信息
				</label>
			</div>
			<div class="col-sm-6 mt10">
				<font face="Courier" class="text-danger">景区或商户或酒店产品
				</font>
			</div>
		</div>

		<div class="form-group">
			<label class="col-sm-2 col-xs-12 control-label checkbox">
				<input type="checkbox" name="template.sys_affirm_type_flag" ng-value="true" ng-model="template.sys_affirm_type_flag" >
				系统确认
			</label>
			<div class="col-sm-4 col-xs-12">
				<label class="radio-inline">
					<input type="radio" name="sys_affirm_type" value="0" ng-model="saleobj.sys_affirm_type" disabled >
					需要确认
				</label>
				<label class="radio-inline">
					<input type="radio" name="sys_affirm_type" value="1" ng-model="saleobj.sys_affirm_type" disabled >
					无需确认
				</label>
			</div>
			<div class="col-sm-6 mt10">
				<font face="Courier" class="text-danger">对接产品需要到第三方系统下单，请选择需要确认
				</font>
			</div>
		</div>

		<div class="form-group">
			<label class="col-sm-2 col-xs-12 control-label checkbox">
				<input type="checkbox" name="template.is_platform_sale_flag" ng-value="true" ng-model="template.is_platform_sale_flag" >
				平台产品
			</label>
			<div class="col-sm-4 col-xs-12">
				<label class="radio-inline">
					<input type="radio" name="is_platform_sale" value="1" ng-model="saleobj.is_platform_sale" disabled >
					是
				</label>
				<label class="radio-inline">
					<input type="radio" name="is_platform_sale" value="0" ng-model="saleobj.is_platform_sale" disabled >
					否
				</label>
			</div>
			<div class="col-sm-6 mt10">
				<font face="Courier" class="text-danger">平台产品需平台审核, 可参与平台分销. 非平台产品, 只可在自有渠道销售.
				</font>
			</div>
		</div>

		<div class="form-group">
			<label class="col-sm-2 col-xs-12 control-label"></label>
			<div class="col-sm-4 col-xs-12 text-center">
				<button type="button" class="btn btn-primary btn-lg btn-block" ng-click="save()">
					保存
				</button>
			</div>
			<div class="col-sm-4">
			</div>
		</div>
		<br />
		<br />
		<br />
		<br />

	</div>
</div>